/**
 * Created by Joe on 2017/7/5 0005.
 */
$(document).ready(function () {

    var table = $('#DataTables_shoppingcart_history').DataTable({
        "paging": true,
        "searching": true,
        "info": true,
        "ordering": true,
        "language": {
            "url": "../vendor/datatables/zh-cn.json"
        }
    });

    $('#DataTables_shoppingcart_history tbody').on('click', 'tr', function () {
        var data = table.row(this).data();
        // toastr.info('您单击了"' + data[0] + '"的行');
    });


    var table = $('#DataTables_shoppingcart').DataTable({
        "paging": true,
        "searching": true,
        "info": true,
        "ordering": true,
        "language": {
            "url": "../vendor/datatables/zh-cn.json"
        }
    });

    $('#DataTables_shoppingcart tbody').on('click', 'tr', function () {
        var data = table.row(this).data();
        // toastr.info('您单击了"' + data[0] + '"的行');
    });

    $('.btn-detail-shoppingcart').on('click',  function () {
       $("#shoppingcart-modal").modal("toggle");
    });

});
